﻿using System;
using System.Collections.Generic;
using System.Runtime.Serialization;
using InstaSharp.Models;

namespace SoundcloudSharp.Model
{
    /// <summary>
    /// SoundCloud user.
    /// </summary>
    public class User
    {
        #region Properties

        [JsonMapping("id", JsonMapping.MappingType.Primitive)]
        public int Id { get; set; }

        [JsonMapping("permalink", JsonMapping.MappingType.Primitive)]
        public string Permalink { get; set; }

        [JsonMapping("username", JsonMapping.MappingType.Primitive)]
        public string UserName { get; set; }

        [JsonMapping("uri", JsonMapping.MappingType.Primitive)]
        public string Uri { get; set; }

        [JsonMapping("permalink_url", JsonMapping.MappingType.Primitive)]
        public string PermalinkUrl { get; set; }

        [JsonMapping("avatar_url", JsonMapping.MappingType.Primitive)]
        public string Avatar { get; set; }

        [JsonMapping("country", JsonMapping.MappingType.Primitive)]
        public string Country { get; set; }

        [JsonMapping("full_name", JsonMapping.MappingType.Primitive)]
        public string FullName { get; set; }

        [JsonMapping("city", JsonMapping.MappingType.Primitive)]
        public string City { get; set; }

        [JsonMapping("description", JsonMapping.MappingType.Primitive)]
        public string Description { get; set; }

        [JsonMapping("discogs_name", JsonMapping.MappingType.Primitive)]
        public string Discogs { get; set; }

        [JsonMapping("myspace_name", JsonMapping.MappingType.Primitive)]
        public string Myspace { get; set; }

        [JsonMapping("website", JsonMapping.MappingType.Primitive)]
        public string Website { get; set; }

        [JsonMapping("website_title", JsonMapping.MappingType.Primitive)]
        public string WebsiteTitle { get; set; }

        [JsonMapping("online", JsonMapping.MappingType.Primitive)]
        public bool IsOnline { get; set; }

        [JsonMapping("track_count", JsonMapping.MappingType.Primitive)]
        public int Tracks { get; set; }

        [JsonMapping("playlist_count", JsonMapping.MappingType.Primitive)]
        public int Playlists { get; set; }

        [JsonMapping("followers_count", JsonMapping.MappingType.Primitive)]
        public int Followers { get; set; }

        [JsonMapping("followings_count", JsonMapping.MappingType.Primitive)]
        public int Followings { get; set; }

        [JsonMapping("public_favorites_count", JsonMapping.MappingType.Primitive)]
        public int Favorites { get; set; }

        [JsonMapping("plan", JsonMapping.MappingType.Primitive)]
        public string Plan { get; set; }

        [JsonMapping("private_tracks_count", JsonMapping.MappingType.Primitive)]
        public int PrivateTracks { get; set; }

        [JsonMapping("private_playlists_count", JsonMapping.MappingType.Primitive)]
        public int PrivatePlaylists { get; set; }

        [JsonMapping("primary_email_confirmed", JsonMapping.MappingType.Primitive)]
        public bool EmailConfirmed { get; set; }

        #endregion Properties

    }

    /// <summary>
    /// Упрощенное представление пользователя
    /// </summary>
    public class UserSmall
    {
        #region Properties

        [JsonMapping("id", JsonMapping.MappingType.Primitive)]
        public int Id { get; set; }

        [JsonMapping("kind", JsonMapping.MappingType.Primitive)]
        public string Kind { get; set; }

        [JsonMapping("permalink", JsonMapping.MappingType.Primitive)]
        public string Permalink { get; set; }

        [JsonMapping("username", JsonMapping.MappingType.Primitive)]
        public string UserName { get; set; }

        [JsonMapping("uri", JsonMapping.MappingType.Primitive)]
        public string Uri { get; set; }

        [JsonMapping("permalink_url", JsonMapping.MappingType.Primitive)]
        public string PermalinkUrl { get; set; }

        [JsonMapping("avatar_url", JsonMapping.MappingType.Primitive)]
        public string Avatar { get; set; }

        #endregion Properties
    }
}